<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html">
    <h:head>
        <title>
            <h:outputText value="#{caption.manutencaoVeiculo}"/>
        </title>
    </h:head>
    <h:body>
        <li><a href="/web_springsecurity/logout">Log Out</a></li>
        <h:form>
            <h:outputText value="#{caption.nome}"/>
            <h:inputText id="nome" value="#{veiculosBean.veiculo.nome}"/>
            <br/>
            <h:outputText value="#{caption.cor}"/>
            <h:inputText id="cor" value="#{veiculosBean.veiculo.cor}"/>
            <br/>
            <h:commandButton value="#{caption.salvar}" 
                             action="#{veiculosBean.inserir()}" 
                             rendered="#{!(veiculosBean.veiculo.id>0)}"/>
            <h:commandButton value="#{caption.atualizar}" 
                             action="#{veiculosBean.atualizar()}" 
                             rendered="#{veiculosBean.veiculo.id>0}"/>
        </h:form>
    </h:body>
</html>

